﻿using System;
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ServiceSecurity
{
    public class SimpleServiceSecurity : IServiceSecurity
    {
        private string _savedHash;
        public SimpleServiceSecurity()
        {
            _savedHash = ConfigurationManager.AppSettings["ServiceSecurityHash"] ?? "";
        }
        public bool ValidateHash(string hash)
        {            
            return hash == _savedHash;
        }
    }
}
